home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 60.zip / BS1 part 60 / Highspeed pascal.adf / Interface / Timer.pas < prev    next >
Pascal/Delphi Source File  |  1992-01-16  |  609b  |  49 lines

  1. Unit Timer;
  2.  
  3. Interface
  4. Uses Exec;
  5.  
  6. Type
  7.   ttimeval = Record
  8.           tv_secs: LongInt;
  9.           tv_micro: LongInt;
  10.         End;
  11.  
  12.   ttimerequest = Record
  13.           tr_node: tIORequest;
  14.           tr_time: ttimeval;
  15.         End;
  16.  
  17.   ptimeval = ^ttimeval;
  18.   pLibrary = ^tLibrary;
  19.  
  20.  
  21. Var
  22.   TimerBase: pLibrary;
  23.  
  24.  
  25. Const
  26.   TR_ADDREQUEST = $9;
  27.   TR_GETSYSTIME = $A;
  28.   TR_SETSYSTIME = $B;
  29.   UNIT_MICROHZ = $0;
  30.   UNIT_VBLANK = $1;
  31.   TIMERNAME = 'timer.device';
  32.  
  33.  
  34. Procedure AddTime
  35.          (dest: ptimeval;
  36.           src: ptimeval);
  37.  
  38. Procedure SubTime
  39.          (dest: ptimeval;
  40.           src: ptimeval);
  41.  
  42. Function CmpTime
  43.          (dest: ptimeval;
  44.           src: ptimeval): LongInt;
  45.  
  46.  
  47.  
  48. End.
  49.